import { createApp } from "vue";
import { createPinia } from "pinia";
import "./style.css";
import App from "./App.vue";

// 如果使用 unplugin-element-plus 并且只使用组件 API，你需要手动导入样式。
import "element-plus/es/components/message/style/css";
import "element-plus/dist/index.css";
import { ElMessage } from "element-plus";
import * as ElementPlusIconsVue from "@element-plus/icons-vue";

console.log(
  "%c 功不唐捐，玉汝于成 %c 致你我",
  "color: orange;font-size: 24px;font-weight: bold;font-style:italic",
  "color:tomato;font-size:14px;font-weight: bold;"
);

const app = createApp(App);

for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component);
}

const pinia = createPinia();
import Directive from "./directives";
app.use(Directive);
app.use(pinia).use(ElMessage).mount("#app");
